<!doctype html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
		<link href="../css/mui.min.css" rel="stylesheet" />
		<style>
					img{
			width:12%;
			border-radius:100%;
			border:1px solid whitesmoke;
		}
		.indexBox{
			width:100%;
			height: 106%;
			border: 1px solid lightgrey;
			list-style: none;
		}
		.mi{
			margin-bottom:12px ;
		}
		</style>
	</head>
	

	<body>
		<script src="js/mui.min.js"></script>
		<header class="mui-bar mui-bar-nav">
		    <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"  onclick="location='homepage.html'"></a>
		    <h1 class="mui-title">我的文章</h1>
		</header>
		<div class="mui-content">
			<ul style="padding: 0;"></ul>
		</div>
	</body>
	<script>
function newblok(i){
			var at = "a"+i;
			at.toString();
			var h = "h"+i;
			h.toString();
			
			var header = window.localStorage.getItem(h);
			var article = window.localStorage.getItem(at);
			var username = window.localStorage.username;
			 
			var mcontent = document.getElementsByTagName("ul")[0];
			var a = document.createElement("li");
			a.setAttribute('class','indexBox');
			var b = document.createElement('div');
			b.setAttribute('class','container');
			var c = document.createElement('img');
			c.setAttribute('src','../img/profile.jpg');
			c.setAttribute('onclick','location="userpage.html"');
			var d = document.createElement('a');
			d.innerHTML=username;
			d.setAttribute('onclick','location="userpage.html"');
			var e = document.createElement('small');
			e.setAttribute("font-size","15px");
			e.innerHTML="发布";
			var f = document.createElement('b');
			f.innerHTML=header;
			f.setAttribute('onclick','sendheader(this)');
			var g = document.createElement('p');
			g.innerHTML=article;
			g.setAttribute('onclick','location="article.html"');
			var z =document.createElement("br");
			
			
				var h = document.createElement('span');
				var i = document.createElement('a');
				i.setAttribute("class",a);
				i.setAttribute("class","mi mui-icon mui-icon-more pull-right");
				h.append(i);
				
				var j = document.createElement('span');
				var k = document.createElement('a');
				k.setAttribute("class",a);
				k.setAttribute("class","mi mui-icon mui-icon-email pull-right");
				j.append(k);

			
			b.append(c);
			b.append(d);
			b.append(d);
			b.append(e);
			b.append(f);
			b.append(h);
			b.append(g);
			b.append(j);
			b.append(z);
			a.append(b);
						
			mcontent.append(a);
		};
		
				function sendheader(a){
			var hd = a.innerHTML;			
			
			var noa = window.localStorage.getItem("noa");
			for(var i=0;i<noa;i++){
				var a = i;
				a++;
				var h = "h"+a;
				h.toString();
				var noad = window.localStorage.getItem(h);
				if(hd==noad){
					var aa = "a"+a;
					aa.toString();
					var at=window.localStorage.getItem(aa);
					
					window.localStorage.setItem("thisat",at);
					window.localStorage.setItem("thishd",hd);
					
					window.location.href="article.html";
				}
			}
		};
		
				function dasdd(){
			//var Request=new UrlSearch(); 
			if(window.localStorage.noai!=window.localStorage.noa){
			var header = getQueryString('header');
			var article = getQueryString('article');
			window.localStorage.hd=header;
			window.localStorage.at=article;
			}
		};
		
					window.onload=function(){
				var noa = window.localStorage.noa;
				for(var i=noa;i>0;i--){
					newblok(i);
				}
			};
	</script>

</html>